﻿<!DOCTYPE html>
<!--[if IE]><![endif]-->
<html>
  
  <head>
    <meta charset="utf-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
    <title>Class LUDecomposition
   </title>
    <meta name="viewport" content="width=device-width">
    <meta name="title" content="Class LUDecomposition
   ">
    <meta name="generator" content="docfx 2.56.4.0">
    
    <link rel="shortcut icon" href="../favicon.ico">
    <link rel="stylesheet" href="../styles/docfx.vendor.css">
    <link rel="stylesheet" href="../styles/docfx.css">
    <link rel="stylesheet" href="../styles/main.css">
    <meta property="docfx:navrel" content="../toc.html">
    <meta property="docfx:tocrel" content="toc.html">
    
    
    
  </head>
  <body data-spy="scroll" data-target="#affix" data-offset="120">
    <div id="wrapper">
      <header>
        
        <nav id="autocollapse" class="navbar navbar-inverse ng-scope" role="navigation">
          <div class="container">
            <div class="navbar-header">
              <button type="button" class="navbar-toggle" data-toggle="collapse" data-target="#navbar">
                <span class="sr-only">Toggle navigation</span>
                <span class="icon-bar"></span>
                <span class="icon-bar"></span>
                <span class="icon-bar"></span>
              </button>
              
              <a class="navbar-brand" href="../index.html">
                <img id="logo" class="svg" src="../logo.svg" alt="">
              </a>
            </div>
            <div class="collapse navbar-collapse" id="navbar">
              <form class="navbar-form navbar-right" role="search" id="search">
                <div class="form-group">
                  <input type="text" class="form-control" id="search-query" placeholder="Search" autocomplete="off">
                </div>
              </form>
            </div>
          </div>
        </nav>
        
        <div class="subnav navbar navbar-default">
          <div class="container hide-when-search" id="breadcrumb">
            <ul class="breadcrumb">
              <li></li>
            </ul>
          </div>
        </div>
      </header>
      <div role="main" class="container body-content hide-when-search">
        
        <div class="sidenav hide-when-search">
          <a class="btn toc-toggle collapse" data-toggle="collapse" href="#sidetoggle" aria-expanded="false" aria-controls="sidetoggle">Show / Hide Table of Contents</a>
          <div class="sidetoggle collapse" id="sidetoggle">
            <div id="sidetoc"></div>
          </div>
        </div>
        <div class="article row grid-right">
          <div class="col-md-10">
            <article class="content wrap" id="_content" data-uid="CADability.LinearAlgebra.LUDecomposition">
  
  
  <h1 id="CADability_LinearAlgebra_LUDecomposition" data-uid="CADability.LinearAlgebra.LUDecomposition" class="text-break">Class LUDecomposition
  </h1>
  <div class="markdown level0 summary"><p>LU Decomposition.</p>
</div>
  <div class="markdown level0 conceptual"></div>
  <div class="inheritance">
    <h5>Inheritance</h5>
    <div class="level0"><span class="xref">System.Object</span></div>
    <div class="level1"><span class="xref">LUDecomposition</span></div>
  </div>
  <div class="inheritedMembers">
    <h5>Inherited Members</h5>
    <div>
      <span class="xref">System.Object.Equals(System.Object)</span>
    </div>
    <div>
      <span class="xref">System.Object.Equals(System.Object, System.Object)</span>
    </div>
    <div>
      <span class="xref">System.Object.GetHashCode()</span>
    </div>
    <div>
      <span class="xref">System.Object.GetType()</span>
    </div>
    <div>
      <span class="xref">System.Object.MemberwiseClone()</span>
    </div>
    <div>
      <span class="xref">System.Object.ReferenceEquals(System.Object, System.Object)</span>
    </div>
    <div>
      <span class="xref">System.Object.ToString()</span>
    </div>
  </div>
  <h6><strong>Namespace</strong>: <a class="xref" href="CADability.LinearAlgebra.html">CADability.LinearAlgebra</a></h6>
  <h6><strong>Assembly</strong>: CADability.dll</h6>
  <h5 id="CADability_LinearAlgebra_LUDecomposition_syntax">Syntax</h5>
  <div class="codewrapper">
    <pre><code class="lang-csharp hljs">[Serializable]
public class LUDecomposition</code></pre>
  </div>
  <h5 id="CADability_LinearAlgebra_LUDecomposition_remarks"><strong>Remarks</strong></h5>
  <div class="markdown level0 remarks"><p>For an m-by-n matrix A with m &gt;= n, the LU decomposition is an m-by-n
unit lower triangular matrix L, an n-by-n upper triangular matrix U,
and a permutation vector piv of length m so that A(piv,:) = L*U.
<code> If m &lt; n, then L is m-by-m and U is m-by-n. </code>
The LU decompostion with pivoting always exists, even if the matrix is
singular, so the constructor will never fail.  The primary use of the
LU decomposition is in the solution of square systems of simultaneous
linear equations.  This will fail if IsNonSingular() returns false.</p>
</div>
  <h3 id="constructors">Constructors
  </h3>
  <span class="small pull-right mobile-hide">
    <span class="divider">|</span>
    <a href="https://github.com/SOFAgh/CADability/new/NonPeriodicAndImplicitSurfaces/apiSpec/new?filename=CADability_LinearAlgebra_LUDecomposition__ctor_CADability_LinearAlgebra_Matrix_.md&amp;value=---%0Auid%3A%20CADability.LinearAlgebra.LUDecomposition.%23ctor(CADability.LinearAlgebra.Matrix)%0Asummary%3A%20'*You%20can%20override%20summary%20for%20the%20API%20here%20using%20*MARKDOWN*%20syntax'%0A---%0A%0A*Please%20type%20below%20more%20information%20about%20this%20API%3A*%0A%0A">Improve this Doc</a>
  </span>
  <span class="small pull-right mobile-hide">
    <a href="https://github.com/SOFAgh/CADability/blob/NonPeriodicAndImplicitSurfaces/CADability/LUDecomposition.cs/#L76">View Source</a>
  </span>
  <a id="CADability_LinearAlgebra_LUDecomposition__ctor_" data-uid="CADability.LinearAlgebra.LUDecomposition.#ctor*"></a>
  <h4 id="CADability_LinearAlgebra_LUDecomposition__ctor_CADability_LinearAlgebra_Matrix_" data-uid="CADability.LinearAlgebra.LUDecomposition.#ctor(CADability.LinearAlgebra.Matrix)">LUDecomposition(Matrix)</h4>
  <div class="markdown level1 summary"><p>LU Decomposition</p>
</div>
  <div class="markdown level1 conceptual"></div>
  <h5 class="decalaration">Declaration</h5>
  <div class="codewrapper">
    <pre><code class="lang-csharp hljs">public LUDecomposition(Matrix A)</code></pre>
  </div>
  <h5 class="parameters">Parameters</h5>
  <table class="table table-bordered table-striped table-condensed">
    <thead>
      <tr>
        <th>Type</th>
        <th>Name</th>
        <th>Description</th>
      </tr>
    </thead>
    <tbody>
      <tr>
        <td><a class="xref" href="CADability.LinearAlgebra.Matrix.html">Matrix</a></td>
        <td><span class="parametername">A</span></td>
        <td><p>Rectangular matrix</p>
</td>
      </tr>
    </tbody>
  </table>
  <h3 id="properties">Properties
  </h3>
  <span class="small pull-right mobile-hide">
    <span class="divider">|</span>
    <a href="https://github.com/SOFAgh/CADability/new/NonPeriodicAndImplicitSurfaces/apiSpec/new?filename=CADability_LinearAlgebra_LUDecomposition_DoublePivot.md&amp;value=---%0Auid%3A%20CADability.LinearAlgebra.LUDecomposition.DoublePivot%0Asummary%3A%20'*You%20can%20override%20summary%20for%20the%20API%20here%20using%20*MARKDOWN*%20syntax'%0A---%0A%0A*Please%20type%20below%20more%20information%20about%20this%20API%3A*%0A%0A">Improve this Doc</a>
  </span>
  <span class="small pull-right mobile-hide">
    <a href="https://github.com/SOFAgh/CADability/blob/NonPeriodicAndImplicitSurfaces/CADability/LUDecomposition.cs/#L245">View Source</a>
  </span>
  <a id="CADability_LinearAlgebra_LUDecomposition_DoublePivot_" data-uid="CADability.LinearAlgebra.LUDecomposition.DoublePivot*"></a>
  <h4 id="CADability_LinearAlgebra_LUDecomposition_DoublePivot" data-uid="CADability.LinearAlgebra.LUDecomposition.DoublePivot">DoublePivot</h4>
  <div class="markdown level1 summary"><p>Returns pivot permutation vector as a one-dimensional double array.</p>
</div>
  <div class="markdown level1 conceptual"></div>
  <h5 class="decalaration">Declaration</h5>
  <div class="codewrapper">
    <pre><code class="lang-csharp hljs">public double[] DoublePivot { get; }</code></pre>
  </div>
  <h5 class="propertyValue">Property Value</h5>
  <table class="table table-bordered table-striped table-condensed">
    <thead>
      <tr>
        <th>Type</th>
        <th>Description</th>
      </tr>
    </thead>
    <tbody>
      <tr>
        <td><span class="xref">System.Double</span>[]</td>
        <td></td>
      </tr>
    </tbody>
  </table>
  <span class="small pull-right mobile-hide">
    <span class="divider">|</span>
    <a href="https://github.com/SOFAgh/CADability/new/NonPeriodicAndImplicitSurfaces/apiSpec/new?filename=CADability_LinearAlgebra_LUDecomposition_IsNonSingular.md&amp;value=---%0Auid%3A%20CADability.LinearAlgebra.LUDecomposition.IsNonSingular%0Asummary%3A%20'*You%20can%20override%20summary%20for%20the%20API%20here%20using%20*MARKDOWN*%20syntax'%0A---%0A%0A*Please%20type%20below%20more%20information%20about%20this%20API%3A*%0A%0A">Improve this Doc</a>
  </span>
  <span class="small pull-right mobile-hide">
    <a href="https://github.com/SOFAgh/CADability/blob/NonPeriodicAndImplicitSurfaces/CADability/LUDecomposition.cs/#L156">View Source</a>
  </span>
  <a id="CADability_LinearAlgebra_LUDecomposition_IsNonSingular_" data-uid="CADability.LinearAlgebra.LUDecomposition.IsNonSingular*"></a>
  <h4 id="CADability_LinearAlgebra_LUDecomposition_IsNonSingular" data-uid="CADability.LinearAlgebra.LUDecomposition.IsNonSingular">IsNonSingular</h4>
  <div class="markdown level1 summary"><p>Indicates whether the matrix is nonsingular.</p>
</div>
  <div class="markdown level1 conceptual"></div>
  <h5 class="decalaration">Declaration</h5>
  <div class="codewrapper">
    <pre><code class="lang-csharp hljs">public bool IsNonSingular { get; }</code></pre>
  </div>
  <h5 class="propertyValue">Property Value</h5>
  <table class="table table-bordered table-striped table-condensed">
    <thead>
      <tr>
        <th>Type</th>
        <th>Description</th>
      </tr>
    </thead>
    <tbody>
      <tr>
        <td><span class="xref">System.Boolean</span></td>
        <td><p><code>true</code> if U, and hence A, is nonsingular.</p>
</td>
      </tr>
    </tbody>
  </table>
  <span class="small pull-right mobile-hide">
    <span class="divider">|</span>
    <a href="https://github.com/SOFAgh/CADability/new/NonPeriodicAndImplicitSurfaces/apiSpec/new?filename=CADability_LinearAlgebra_LUDecomposition_L.md&amp;value=---%0Auid%3A%20CADability.LinearAlgebra.LUDecomposition.L%0Asummary%3A%20'*You%20can%20override%20summary%20for%20the%20API%20here%20using%20*MARKDOWN*%20syntax'%0A---%0A%0A*Please%20type%20below%20more%20information%20about%20this%20API%3A*%0A%0A">Improve this Doc</a>
  </span>
  <span class="small pull-right mobile-hide">
    <a href="https://github.com/SOFAgh/CADability/blob/NonPeriodicAndImplicitSurfaces/CADability/LUDecomposition.cs/#L168">View Source</a>
  </span>
  <a id="CADability_LinearAlgebra_LUDecomposition_L_" data-uid="CADability.LinearAlgebra.LUDecomposition.L*"></a>
  <h4 id="CADability_LinearAlgebra_LUDecomposition_L" data-uid="CADability.LinearAlgebra.LUDecomposition.L">L</h4>
  <div class="markdown level1 summary"><p>Gets lower triangular factor.</p>
</div>
  <div class="markdown level1 conceptual"></div>
  <h5 class="decalaration">Declaration</h5>
  <div class="codewrapper">
    <pre><code class="lang-csharp hljs">public Matrix L { get; }</code></pre>
  </div>
  <h5 class="propertyValue">Property Value</h5>
  <table class="table table-bordered table-striped table-condensed">
    <thead>
      <tr>
        <th>Type</th>
        <th>Description</th>
      </tr>
    </thead>
    <tbody>
      <tr>
        <td><a class="xref" href="CADability.LinearAlgebra.Matrix.html">Matrix</a></td>
        <td></td>
      </tr>
    </tbody>
  </table>
  <span class="small pull-right mobile-hide">
    <span class="divider">|</span>
    <a href="https://github.com/SOFAgh/CADability/new/NonPeriodicAndImplicitSurfaces/apiSpec/new?filename=CADability_LinearAlgebra_LUDecomposition_Pivot.md&amp;value=---%0Auid%3A%20CADability.LinearAlgebra.LUDecomposition.Pivot%0Asummary%3A%20'*You%20can%20override%20summary%20for%20the%20API%20here%20using%20*MARKDOWN*%20syntax'%0A---%0A%0A*Please%20type%20below%20more%20information%20about%20this%20API%3A*%0A%0A">Improve this Doc</a>
  </span>
  <span class="small pull-right mobile-hide">
    <a href="https://github.com/SOFAgh/CADability/blob/NonPeriodicAndImplicitSurfaces/CADability/LUDecomposition.cs/#L228">View Source</a>
  </span>
  <a id="CADability_LinearAlgebra_LUDecomposition_Pivot_" data-uid="CADability.LinearAlgebra.LUDecomposition.Pivot*"></a>
  <h4 id="CADability_LinearAlgebra_LUDecomposition_Pivot" data-uid="CADability.LinearAlgebra.LUDecomposition.Pivot">Pivot</h4>
  <div class="markdown level1 summary"><p>Gets pivot permutation vector</p>
</div>
  <div class="markdown level1 conceptual"></div>
  <h5 class="decalaration">Declaration</h5>
  <div class="codewrapper">
    <pre><code class="lang-csharp hljs">public int[] Pivot { get; }</code></pre>
  </div>
  <h5 class="propertyValue">Property Value</h5>
  <table class="table table-bordered table-striped table-condensed">
    <thead>
      <tr>
        <th>Type</th>
        <th>Description</th>
      </tr>
    </thead>
    <tbody>
      <tr>
        <td><span class="xref">System.Int32</span>[]</td>
        <td></td>
      </tr>
    </tbody>
  </table>
  <span class="small pull-right mobile-hide">
    <span class="divider">|</span>
    <a href="https://github.com/SOFAgh/CADability/new/NonPeriodicAndImplicitSurfaces/apiSpec/new?filename=CADability_LinearAlgebra_LUDecomposition_U.md&amp;value=---%0Auid%3A%20CADability.LinearAlgebra.LUDecomposition.U%0Asummary%3A%20'*You%20can%20override%20summary%20for%20the%20API%20here%20using%20*MARKDOWN*%20syntax'%0A---%0A%0A*Please%20type%20below%20more%20information%20about%20this%20API%3A*%0A%0A">Improve this Doc</a>
  </span>
  <span class="small pull-right mobile-hide">
    <a href="https://github.com/SOFAgh/CADability/blob/NonPeriodicAndImplicitSurfaces/CADability/LUDecomposition.cs/#L200">View Source</a>
  </span>
  <a id="CADability_LinearAlgebra_LUDecomposition_U_" data-uid="CADability.LinearAlgebra.LUDecomposition.U*"></a>
  <h4 id="CADability_LinearAlgebra_LUDecomposition_U" data-uid="CADability.LinearAlgebra.LUDecomposition.U">U</h4>
  <div class="markdown level1 summary"><p>Gets upper triangular factor.</p>
</div>
  <div class="markdown level1 conceptual"></div>
  <h5 class="decalaration">Declaration</h5>
  <div class="codewrapper">
    <pre><code class="lang-csharp hljs">public Matrix U { get; }</code></pre>
  </div>
  <h5 class="propertyValue">Property Value</h5>
  <table class="table table-bordered table-striped table-condensed">
    <thead>
      <tr>
        <th>Type</th>
        <th>Description</th>
      </tr>
    </thead>
    <tbody>
      <tr>
        <td><a class="xref" href="CADability.LinearAlgebra.Matrix.html">Matrix</a></td>
        <td></td>
      </tr>
    </tbody>
  </table>
  <h3 id="methods">Methods
  </h3>
  <span class="small pull-right mobile-hide">
    <span class="divider">|</span>
    <a href="https://github.com/SOFAgh/CADability/new/NonPeriodicAndImplicitSurfaces/apiSpec/new?filename=CADability_LinearAlgebra_LUDecomposition_Determinant.md&amp;value=---%0Auid%3A%20CADability.LinearAlgebra.LUDecomposition.Determinant%0Asummary%3A%20'*You%20can%20override%20summary%20for%20the%20API%20here%20using%20*MARKDOWN*%20syntax'%0A---%0A%0A*Please%20type%20below%20more%20information%20about%20this%20API%3A*%0A%0A">Improve this Doc</a>
  </span>
  <span class="small pull-right mobile-hide">
    <a href="https://github.com/SOFAgh/CADability/blob/NonPeriodicAndImplicitSurfaces/CADability/LUDecomposition.cs/#L268">View Source</a>
  </span>
  <a id="CADability_LinearAlgebra_LUDecomposition_Determinant_" data-uid="CADability.LinearAlgebra.LUDecomposition.Determinant*"></a>
  <h4 id="CADability_LinearAlgebra_LUDecomposition_Determinant" data-uid="CADability.LinearAlgebra.LUDecomposition.Determinant">Determinant()</h4>
  <div class="markdown level1 summary"><p>Determinant</p>
</div>
  <div class="markdown level1 conceptual"></div>
  <h5 class="decalaration">Declaration</h5>
  <div class="codewrapper">
    <pre><code class="lang-csharp hljs">public double Determinant()</code></pre>
  </div>
  <h5 class="returns">Returns</h5>
  <table class="table table-bordered table-striped table-condensed">
    <thead>
      <tr>
        <th>Type</th>
        <th>Description</th>
      </tr>
    </thead>
    <tbody>
      <tr>
        <td><span class="xref">System.Double</span></td>
        <td><p>det(A)</p>
</td>
      </tr>
    </tbody>
  </table>
  <h5 class="exceptions">Exceptions</h5>
  <table class="table table-bordered table-striped table-condensed">
    <thead>
      <tr>
        <th>Type</th>
        <th>Condition</th>
      </tr>
    </thead>
    <tbody>
      <tr>
        <td><span class="xref">System.ArgumentException</span></td>
        <td><p>Matrix must be square</p>
</td>
      </tr>
    </tbody>
  </table>
  <span class="small pull-right mobile-hide">
    <span class="divider">|</span>
    <a href="https://github.com/SOFAgh/CADability/new/NonPeriodicAndImplicitSurfaces/apiSpec/new?filename=CADability_LinearAlgebra_LUDecomposition_Solve_CADability_LinearAlgebra_Matrix_.md&amp;value=---%0Auid%3A%20CADability.LinearAlgebra.LUDecomposition.Solve(CADability.LinearAlgebra.Matrix)%0Asummary%3A%20'*You%20can%20override%20summary%20for%20the%20API%20here%20using%20*MARKDOWN*%20syntax'%0A---%0A%0A*Please%20type%20below%20more%20information%20about%20this%20API%3A*%0A%0A">Improve this Doc</a>
  </span>
  <span class="small pull-right mobile-hide">
    <a href="https://github.com/SOFAgh/CADability/blob/NonPeriodicAndImplicitSurfaces/CADability/LUDecomposition.cs/#L287">View Source</a>
  </span>
  <a id="CADability_LinearAlgebra_LUDecomposition_Solve_" data-uid="CADability.LinearAlgebra.LUDecomposition.Solve*"></a>
  <h4 id="CADability_LinearAlgebra_LUDecomposition_Solve_CADability_LinearAlgebra_Matrix_" data-uid="CADability.LinearAlgebra.LUDecomposition.Solve(CADability.LinearAlgebra.Matrix)">Solve(Matrix)</h4>
  <div class="markdown level1 summary"><p>Solve A*X = B</p>
</div>
  <div class="markdown level1 conceptual"></div>
  <h5 class="decalaration">Declaration</h5>
  <div class="codewrapper">
    <pre><code class="lang-csharp hljs">public Matrix Solve(Matrix B)</code></pre>
  </div>
  <h5 class="parameters">Parameters</h5>
  <table class="table table-bordered table-striped table-condensed">
    <thead>
      <tr>
        <th>Type</th>
        <th>Name</th>
        <th>Description</th>
      </tr>
    </thead>
    <tbody>
      <tr>
        <td><a class="xref" href="CADability.LinearAlgebra.Matrix.html">Matrix</a></td>
        <td><span class="parametername">B</span></td>
        <td><p>A Matrix with as many rows as A and any number of columns.</p>
</td>
      </tr>
    </tbody>
  </table>
  <h5 class="returns">Returns</h5>
  <table class="table table-bordered table-striped table-condensed">
    <thead>
      <tr>
        <th>Type</th>
        <th>Description</th>
      </tr>
    </thead>
    <tbody>
      <tr>
        <td><a class="xref" href="CADability.LinearAlgebra.Matrix.html">Matrix</a></td>
        <td><p>X so that L<em>U</em>X = B(piv,:)</p>
</td>
      </tr>
    </tbody>
  </table>
  <h5 class="exceptions">Exceptions</h5>
  <table class="table table-bordered table-striped table-condensed">
    <thead>
      <tr>
        <th>Type</th>
        <th>Condition</th>
      </tr>
    </thead>
    <tbody>
      <tr>
        <td><span class="xref">System.ArgumentException</span></td>
        <td><p>Matrix row dimensions must agree.</p>
</td>
      </tr>
      <tr>
        <td><span class="xref">System.ApplicationException</span></td>
        <td><p>Matrix is singular.</p>
</td>
      </tr>
    </tbody>
  </table>
</article>
          </div>
          
          <div class="hidden-sm col-md-2" role="complementary">
            <div class="sideaffix">
              <div class="contribution">
                <ul class="nav">
                  <li>
                    <a href="https://github.com/SOFAgh/CADability/new/NonPeriodicAndImplicitSurfaces/apiSpec/new?filename=CADability_LinearAlgebra_LUDecomposition.md&amp;value=---%0Auid%3A%20CADability.LinearAlgebra.LUDecomposition%0Asummary%3A%20'*You%20can%20override%20summary%20for%20the%20API%20here%20using%20*MARKDOWN*%20syntax'%0A---%0A%0A*Please%20type%20below%20more%20information%20about%20this%20API%3A*%0A%0A" class="contribution-link">Improve this Doc</a>
                  </li>
                  <li>
                    <a href="https://github.com/SOFAgh/CADability/blob/NonPeriodicAndImplicitSurfaces/CADability/LUDecomposition.cs/#L40" class="contribution-link">View Source</a>
                  </li>
                </ul>
              </div>
              <nav class="bs-docs-sidebar hidden-print hidden-xs hidden-sm affix" id="affix">
                <h5>In This Article</h5>
                <div></div>
              </nav>
            </div>
          </div>
        </div>
      </div>
      
      <footer>
        <div class="grad-bottom"></div>
        <div class="footer">
          <div class="container">
            <span class="pull-right">
              <a href="#top">Back to top</a>
            </span>
            
            <span>Generated by <strong>DocFX</strong></span>
          </div>
        </div>
      </footer>
    </div>
    
    <script type="text/javascript" src="../styles/docfx.vendor.js"></script>
    <script type="text/javascript" src="../styles/docfx.js"></script>
    <script type="text/javascript" src="../styles/main.js"></script>
  </body>
</html>
